/**
 * @author xuyh0817
 * @email xuyh0817@foxmail.com
 * @date 2022-02-16 01:41
 * @version 2.0.0
 * @doc todo
 * @website todo
 * @remark  如果要分发源码，需在本文件顶部保留此文件头信息！！
 */
import { COMPONENT_TYPE } from '../../constants'

export default [
  {
    id: '1',
    type: COMPONENT_TYPE.INPUT,
    formItem: {
      prop: 'value',
      rules: [],
      label: '默认值',
      extra: 'value(v-model) 日期字符串 如 6:4:21',
    },
    attrs: {
      maxLength: 100,
      type: 'text',
      allowClear: true,
      placeholder: '请输入默认值'
    }
  },
  {
    id: '2',
    type: COMPONENT_TYPE.INPUT,
    formItem: {
      prop: 'placeholder',
      rules: [],
      label: '提示内容',
      extra: 'placeholder 提示内容',
    },
    attrs: {
      maxLength: 100,
      value: '请选择时间',
      type: 'text',
      allowClear: true,
      placeholder: '请选择时间'
    }
  },
  {
    id: '3',
    type: COMPONENT_TYPE.INPUT,
    formItem: {
      prop: 'format',
      rules: [],
      label: '时间格式',
      extra: '设置时间格式 HH:mm:ss',
    },
    attrs: {
      value: 'HH:mm:ss',
      maxLength: 30,
      type: 'text',
      allowClear: true,
      placeholder: '请输入时间格式'
    }
  },
  {
    id: '4',
    type: COMPONENT_TYPE.SWITCH,
    formItem: {
      prop: 'showCurrent',
      rules: [],
      label: '此刻按钮',
      extra: '是否展示“此刻”按钮',
    },
    attrs: {
      checked: true
    }
  },
  {
    id: '5',
    type: COMPONENT_TYPE.SWITCH,
    formItem: {
      prop: 'disabled',
      rules: [],
      label: '禁用状态',
      extra: '是否禁用状态，默认为 false',
    },
    attrs: {
      checked: false
    }
  },
  {
    id: '6',
    type: COMPONENT_TYPE.SWITCH,
    formItem: {
      prop: 'isNow',
      rules: [],
      label: '当前时间',
      extra: '默认当前时间',
    },
    attrs: {
      checked: true
    }
  },
  {
    id: '7',
    type: COMPONENT_TYPE.RADIO_BUTTON,
    formItem: {
      prop: 'size',
      rules: [],
      label: '控件大小',
      extra: '控件大小。注：标准表单内的输入框大小限制为 large。可选 large default small ',
    },
    attrs: {
      value: 'default',
      buttonStyle: 'solid',
      children: [
        {
          value: 'large',
          label: 'large'
        },
        {
          value: 'default',
          label: 'default'
        },
        {
          value: 'small',
          label: 'small'
        }
      ]
    }
  },
  {
    id: '8',
    type: COMPONENT_TYPE.SWITCH,
    formItem: {
      prop: 'allowClear',
      rules: [],
      label: '清除图标',
      extra: '可以点击清除图标删除内容，默认为 true',
    },
    attrs: {
      checked: true
    }
  },
  {
    id: '9',
    type: COMPONENT_TYPE.INPUT_NUMBER,
    formItem: {
      prop: 'hourStep',
      rules: [],
      label: '小时间隔',
      extra: '小时选项间隔',
    },
    attrs: {
      value: 1,
      min: 1,
      max: 23,
      allowClear: true,
      placeholder: '请输入小时选项间隔'
    }
  },
  {
    id: '10',
    type: COMPONENT_TYPE.INPUT_NUMBER,
    formItem: {
      prop: 'minuteStep',
      rules: [],
      label: '分钟间隔',
      extra: '分钟选项间隔',
    },
    attrs: {
      value: 1,
      min: 1,
      max: 59,
      allowClear: true,
      placeholder: '请输入分钟选项间隔'
    }
  },
  {
    id: '11',
    type: COMPONENT_TYPE.INPUT_NUMBER,
    formItem: {
      prop: 'secondStep',
      rules: [],
      label: '秒间隔',
      extra: '秒选项间隔',
    },
    attrs: {
      value: 1,
      min: 1,
      max: 59,
      allowClear: true,
      placeholder: '请输入秒选项间隔'
    }
  }
]
